<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="utf-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>企业资料管理</title>
    <script type="text/javascript" charset="utf-8" src="ueditor.config.js"></script>
    <script type="text/javascript" charset="utf-8" src="ueditor.all.min.js"></script>
    <script type="text/javascript" charset="utf-8" src="lang/zh-cn/zh-cn.js"></script>
    <link rel="stylesheet" href="css/font-awesome.min.css"/>
    <link rel="stylesheet" href="css/font-awesome-ie7.min.css"/>
    <link rel="stylesheet" href="css/bootstrap.min.css"/>
    <link rel="stylesheet" href="css/admin.css"/>

    <!--[if lt IE 9]>
    <script src="http://cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js"></script>
    <![endif]-->
    <!--[if lt IE 10]>
    <script src="http://cdn.bootcss.com/jquery/1.11.3/jquery.min.js"></script>
    <script src="http://cdn.bootcss.com/jquery-placeholder/2.0.8/jquery.placeholder.min.js"></script>
    <![endif]-->
    <style>
        .content td input {
            float: left;
        }

    </style>
</head>
<body>
<!-- header start -->
<div id="header"></div>
<!-- header end -->
<!-- usercenter start -->
<div class="usercotent">
    <!-- left start -->
    <div id="center-left"></div>
    <!-- left end -->
    <!-- right start -->
    <div class="usercotentr floatr">
        <div class="user-tit">
            <h3>企业资料管理</h3>
        </div>
        <section id="company">
            <h4>企业信息</h4>
            <div class="content contentTable">
                <table>
                    <tr>
                        <th><em>*</em>企业名称：</th>
                        <td>
                            <!--<span id="GRP_NAME"></span>-->
                            <input style="float: left" name="GRP_NAME" type="text" id="GRP_NAME" value=""/>
                            <div class="clear"></div>
                        </td>
                    </tr>
                    <tr>
                        <th><em>*</em>联系人姓名：</th>
                        <td>
                            <input name="GRP_PERNAME" type="text" id="GRP_PERNAME" value=""/>

                        </td>
                    </tr>
                    <tr>
                        <th style="margin-top: 10px;height: auto"><em>*</em>手机号码：</th>
                        <td>
                        <span id="linktels">

                        </span>
                            <button class="btn btn-success floatl" id="addTel">+</button>
                            <button class="btn btn-danger floatl" id="removeTel">-</button>
                        </td>
                    </tr>
                    <tr>
                        <th>QQ：</th>
                        <td>
                        <span id="linkqqs">

                        </span>
                            <button class="btn btn-success floatl" id="addQQ">+</button>

                            <button class="btn btn-danger floatl" id="removeQQ">-</button>
                        </td>
                    </tr>

                </table>
            </div>
            <h4 style="border-top: 1px solid white;">企业简介</h4>
            <div class="col-md-12">
                <div class="moe-password">

                    <div class="form-group">
                        <!--<label for="inputEmail3" class="col-sm-2 control-label"-->
                               <!--style="width: 150px;background-color: white">详细内容:</label>-->
                        <div class="col-sm-10" style="min-height: 400px;min-width: 900px">
                            <div style="width:100%;">
                                <script id="editor" type="text/plain"
                                        style="width:100%;min-height:500px;margin:auto"></script>
                            </div>
                        </div>
                    </div>

                </div>
            </div>
        </section>
        <input type="submit" name="btn_Save" value="保存" id="btn_Save" class="button"/>
    </div>
    <div class="clear"></div>
    <!-- right end -->
</div>

<!-- usercenter end -->

<!-- footer start -->
<div class="footer">
    <div class="bot">
        <p style="padding-top: 10px; text-align: center">Copyright (C) 都能印 2014-2016, all Rights Reserved |
            豫ICP备14024464号-1 | 增值电信业务经营许可证：豫B2-20150019</p>
        <p class="authentication" style="padding-bottom: 10px; padding-top: 10px;">
            <img src="img/footer1.png" alt="">
            <img src="img/footer2.png" alt="">
            <img src="img/footer3.png" alt="">
            <img src="img/footer4.png" alt="">
            <img src="img/footer5.png" alt="">
        </p>

    </div>
</div>
<!-- footer end -->
<script src="js/jquery.min-1-11-3.js"></script>
<script src="js/sidebar-menu.js"></script>

<script src="js/widget/admin.js"></script>
<script src="js/widget/userdetail.js"></script>
<script>
    $(function () {
        initSideAccMenu("企业资料管理", "企业资料管理");
    });
    //实例化编辑器
    //建议使用工厂方法getEditor创建和引用编辑器实例，如果在某个闭包下引用该编辑器，直接调用UE.getEditor('editor')就能拿到相关的实例
    var ue = UE.getEditor('editor');


    function isFocus(e) {
        alert(UE.getEditor('editor').isFocus());
        UE.dom.domUtils.preventDefault(e)
    }
    function setblur(e) {
        UE.getEditor('editor').blur();
        UE.dom.domUtils.preventDefault(e)
    }
    function insertHtml() {
        var value = prompt('插入html代码', '');
        UE.getEditor('editor').execCommand('insertHtml', value)
    }
    function createEditor() {
        enableBtn();
        UE.getEditor('editor');
    }
    function getAllHtml() {
        alert(UE.getEditor('editor').getAllHtml())
    }
    function getContent() {

    }
    function getPlainTxt() {
        var arr = [];
        arr.push("使用editor.getPlainTxt()方法可以获得编辑器的带格式的纯文本内容");
        arr.push("内容为：");
        arr.push(UE.getEditor('editor').getPlainTxt());
        alert(arr.join('\n'))
    }
    function setContent(isAppendTo) {

        UE.getEditor('editor').setContent(isAppendTo);//输入内容的地方


    }
    function setDisabled() {
        UE.getEditor('editor').setDisabled('fullscreen');
        disableBtn("enable");
    }

    function setEnabled() {
        UE.getEditor('editor').setEnabled();
        enableBtn();
    }

    function getText() {
        //当你点击按钮时编辑区域已经失去了焦点，如果直接用getText将不会得到内容，所以要在选回来，然后取得内容
        var range = UE.getEditor('editor').selection.getRange();
        range.select();
        var txt = UE.getEditor('editor').selection.getText();
        alert(txt)
    }

    function getContentTxt() {
        var arr = [];
        arr.push("使用editor.getContentTxt()方法可以获得编辑器的纯文本内容");
        arr.push("编辑器的纯文本内容为：");
        arr.push(UE.getEditor('editor').getContentTxt());
        alert(arr.join("\n"));
    }
    function hasContent() {
        var arr = [];
        arr.push("使用editor.hasContents()方法判断编辑器里是否有内容");
        arr.push("判断结果为：");
        arr.push(UE.getEditor('editor').hasContents());
        alert(arr.join("\n"));
    }
    function setFocus() {
        UE.getEditor('editor').focus();
    }
    function deleteEditor() {
        disableBtn();
        UE.getEditor('editor').destroy();
    }
    function disableBtn(str) {
        var div = document.getElementById('btns');
        var btns = UE.dom.domUtils.getElementsByTagName(div, "button");
        for (var i = 0, btn; btn = btns[i++];) {
            if (btn.id == str) {
                UE.dom.domUtils.removeAttributes(btn, ["disabled"]);
            } else {
                btn.setAttribute("disabled", "true");
            }
        }
    }
    function enableBtn() {
        var div = document.getElementById('btns');
        var btns = UE.dom.domUtils.getElementsByTagName(div, "button");
        for (var i = 0, btn; btn = btns[i++];) {
            UE.dom.domUtils.removeAttributes(btn, ["disabled"]);
        }
    }

    function getLocalData() {
        alert(UE.getEditor('editor').execCommand("getlocaldata"));
    }

    function clearLocalData() {
        UE.getEditor('editor').execCommand("clearlocaldata");
        alert("已清空草稿箱")
    }
</script>
</body>
</html>